package com.system.stockservice.mapper;

import com.system.commonutils.bean.ApiResult;
import com.system.commonutils.bean.PagesBean;
import com.system.commonutils.pojo.Stock;
import com.system.commonutils.pojo.Stock_info;
import com.system.stockservice.beans.OrderGoodsNumebrBeans;
import feign.Param;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * User: GPC
 * Date: 2020/07/07 8:53
 * Description:
 * Version: V1.0
 */


@Repository("stockMapper")
public interface StockMapper {

    List<Stock> selectStock(Stock stock);

    Integer selectTotal(Stock stock);

    Integer addStock(Stock stock);

    Integer updateStock(Stock stock);

    List<Stock_info> selectinfo(Stock_info stock);

    Integer selectinfoTotal(Stock_info stock);

    Integer updateinfo(Stock_info stock);

    Integer addStockInfo(Stock stock);

    Stock selectStockByName(Stock stock);


    Integer addStockNumber(Stock stock);

    List<Stock> selectByTBId(Stock stock);

    List<OrderGoodsNumebrBeans>  selectByOrderNo(Integer orders_id);

    Integer reduceStock(OrderGoodsNumebrBeans number);

    Integer selectNumerById(Integer stock_id);
}
